//全局数据定义和修改方法
// 1. 导出创建store 的方法
import { legacy_createStore as createStore,combineReducers } from "redux";
import countReducer from "./models/count";
import proReducer from "./models/pro";

//将多个reducer合并为一个reducer
const reducer=combineReducers({
    count:countReducer,
    pro:proReducer
})

//3.通过createStore来创建一个状态管理器
const store = createStore(reducer);

//4.将store导出
export default store;
